package br.com.news.dao.util;

public class RepositoryScript {

	public static final String SCRIPT_DROP_DATABASE = "drop database if exists NewsAndroid";

	public static final String NOME_BANCO = "NewsAndroid";

	public static final int VERSION_ONE = 1;

	public static final String[] COMMANDS_VERSION_ONE = new String[] {
			"create table Categoria(_id integer primary key, descricao text not null);",
			"create table UsuarioAndroid(_id integer primary key);",
			"create table Noticia(_id integer primary key,"
					+ "idcategoria integer NOT NULL CONSTRAINT foreign_categoria_noticia REFERENCES Categoria(_id)," 
					+ "fonte text not null,"
					+ "autor text," 
					+ "datanoticia text not null," 
					+ "texto text," 
					+ "titulo text not null);" };

	public static final int VERSION_TWO = 2;

	public static final String[] COMMANDS_VERSION_TWO = new String[] {"ALTER TABLE Categoria ADD selecionada INTEGER NOT NULL DEFAULT 0;"};
	
}
